/**
 * @file setting_mobile_network.h
 *
 */
#ifndef SETTING_MOBILE_NETWORK_H
#define SETTING_MOBILE_NETWORK_H

#ifdef __cplusplus
extern "C" {
#endif

/*********************
 *      INCLUDES
 *********************/
#ifdef LV_CONF_INCLUDE_SIMPLE
#include "lvgl.h"
#include "lv_watch_conf.h"
#else
#include "../../../lvgl/lvgl.h"
#include "../../../lv_watch_conf.h"
#endif

#if USE_LV_WATCH_MOBILE_NETWORK != 0
/*********************
 *      DEFINES
 *********************/

/**********************
 *      TYPEDEFS
 **********************/
typedef struct {
    lv_watch_obj_ext_t lv_watch_obj;
    /*New data for this type */
    lv_obj_t * label_apn_name;
    char apn_name[NV_MAX_APN_INFO_LEN];
    uint8_t ip_type;
} lv_mobile_network_obj_ext_t;

typedef struct {
    lv_watch_obj_ext_t old_ext;
    lv_obj_t * ta_name;
    lv_obj_t * ddlist_ip_type;
} lv_apn_obj_ext_t;

enum {
    WATCH_CALL_FORWARD_NULL = 0,
    WATCH_CALL_FORWARD_NO_CONDITION,
    WATCH_CALL_FORWARD_BUSY,
    WATCH_CALL_FORWARD_NOT_REACH,
    WATCH_CALL_FORWARD_NO_ANSWER,
};

typedef struct {
    lv_watch_obj_ext_t old_ext;
    lv_obj_t * no_condition_tip_label;
    lv_obj_t * busy_tip_label;
    lv_obj_t * not_reach_tip_label;
    lv_obj_t * no_answer_tip_label;
    lv_obj_t * no_condition_number;
    lv_obj_t * busy_number;
    lv_obj_t * not_reach_number;
    lv_obj_t * no_answer_number;
    uint8_t  divert_page;
} lv_call_forward_obj_ext_t;

/**********************
 * GLOBAL PROTOTYPES
 **********************/
void mobile_network_create_btn_action(lv_obj_t * btn, lv_event_t event);
void mobile_network_init(nv_apn_info *apn_info);
MMI_Modem_Apn_Info_t * mobile_network_get_apn_info(void);

/**********************
 *      MACROS
 **********************/

#endif /*USE_LV_WATCH_MOBILE_NETWORK*/

#ifdef __cplusplus
} /* extern "C" */
#endif

#endif /*SETTING_MOBILE_NETWORK_H*/
